package com.yanxml.spring.history.v3.demo1_component_scan;

import com.yanxml.spring.history.v3.demo1_component_scan.config.JavaConfig;
import com.yanxml.spring.history.v3.demo1_component_scan.service.UserService;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class StartAppDemo1 {
    public static void main(String[] args) {
        ApplicationContext applicationContext = new AnnotationConfigApplicationContext(JavaConfig.class);
        System.out.println(applicationContext.getBean(UserService.class));
    }
}

// demo1_2:
// com.yanxml.spring.history.v3.demo1_component_scan.service.UserService@29176cc1